home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Mac Game Programming Gurus / TricksOfTheMacGameProgrammingGurus.iso / CodeWarrior Lite / Metrowerks C⁄C++ Lite / Headers / ANSI Headers / unix.h < prev    next >
Encoding:
C/C++ Source or Header  |  1995-04-11  |  1.2 KB  |  78 lines  |  [TEXT/MMCC]

  1. /*
  2.  *    File:        unix.h
  3.  *                ©1993-1995 metrowerks Inc. All rights reserved
  4.  *    Author:        Berardino E. Baratta
  5.  *
  6.  *    Content:    Interface file to standard UNIX-style entry points ...
  7.  *
  8.  *    NB:            This file implements some UNIX low level support.  These functions
  9.  *                are not guaranteed to be 100% conformant.
  10.  */
  11.  
  12. #ifndef    _UNIX
  13. #define    _UNIX
  14.  
  15. #ifndef _STDIO
  16. #include <stdio.h>
  17. #endif
  18.  
  19. #ifndef _FCNTL
  20. #include <fcntl.h>
  21. #endif
  22.  
  23. #ifndef _STAT
  24. #include <stat.h>
  25. #endif
  26.  
  27. #ifndef    _UNISTD
  28. #include <unistd.h>
  29. #endif
  30.  
  31. #ifndef _UTIME
  32. #include <utime.h>
  33. #endif
  34.  
  35. #ifndef _UTSNAME
  36. #include <utsname.h>
  37. #endif
  38.  
  39. #pragma options align=mac68k
  40.  
  41. /*
  42.  *    Globals for setting the type and creator of new files ...
  43.  */
  44. extern long _fcreator, _ftype;
  45.  
  46. #ifdef __cplusplus
  47. extern "C" {
  48. #endif
  49.  
  50. /*
  51.  *    Returns the fileid associated with a stream.
  52.  */
  53. int fileno(FILE *stream);
  54.  
  55. /*
  56.  *    Converts a fileid into a stream.
  57.  */
  58. FILE *fdopen(int fildes, char *type);
  59.  
  60. /*
  61.  *    Return the current on disk file position.
  62.  */
  63. long tell(int fildes);
  64.  
  65. /*
  66.  *    Internal ANSI library functions for reading and writing.
  67.  */
  68. int _Fread(FILE *stream, unsigned char *buf, int count);
  69. int _Fwrite(FILE *stream, const unsigned char *buf, int count);
  70.  
  71. #ifdef __cplusplus
  72. }
  73. #endif
  74.  
  75. #pragma options align=reset
  76.  
  77. #endif
  78.